package cn.mapway.tools.rpc.model;

import lombok.Data;

import java.util.List;

/**
 * FieldDefination
 *
 * @author zhangjianshe@gmail.com
 */
@Data
public class FieldDefination {

    Boolean isStatic;
    /**
     * 是否是 模板类型
     */
    Boolean isTemplate;
    String typeName;
    String simpleName;
    Boolean isArrray;
    Boolean isPrimitive;
    String name;
    String summary;
    String example;
    String author;
    //是否必须参数
    Boolean needed;
    //类型实参
    List<String> typeActualParameters;

    public FieldDefination(String typeName, String name) {
        this.typeName = typeName;
        this.simpleName = Types.simpleType(typeName);
        this.isPrimitive = TypeUtil.isPrimitive(typeName);
        this.name = name;
        this.isTemplate = false;
    }
}
